﻿-var entity = ViewData["entity"] as Workflow
-var statuses = ViewData["statuses"] as List<Status>
-var permissions = ViewData["permissions"] as List<Permission>
-var matrix = entity.WorkflowStatusMatrix
-bool create = (entity.Id == 0);
%form.validate{action="workflow.ivp/save",method="post"}
  _formfields
  =HTMLHelper.HiddenInput("id",entity.Id)
  =HTMLHelper.HiddenInput("name",(create) ? "Бизнес-процесс" : entity.Name)
  #content
    .formheader
      %h1=String.Format("<img src=\"img/headericons/workflow.gif\" class=\"icon24\" /> {0}","Матрица переходов статусов")
    _error
    .shadowbg
      .formbody 
        _matrix   
      .formbottom
        %button.save#submit{type="submit",onclick="$('#returnaftersave').val('')"} Сохранить
  #rightmenu
    _configurationmenu
